package com.boot.security.server.agency.service;

import com.boot.security.server.agency.model.domain.AgencyRecord;
import com.boot.security.server.agency.model.param.AgencyParam;
import com.boot.security.server.agency.model.vo.AgencyRecordVo;
import com.boot.security.server.agency.model.vo.AgencyVo;

import java.util.List;

/**
 * 代办业务接口
 * @author king
 */
public interface AgencyRecordService {
    /**
     * 添加
     * @param agencyRecord
     * @return
     */
    int save (AgencyRecord agencyRecord);

    /**
     * 修改
     * @param agencyRecord
     * @return
     */
    int update (AgencyRecord agencyRecord);

    /**
     * 删除
     * @param id
     * @return
     */
    int del (Integer id);

    /**
     * 根据条件删除
     * @param agencyRecord
     * @return
     */
    int delete (AgencyRecord agencyRecord);

    /**
     * 查询所有
     * @return
     */
    List<AgencyRecord> findByAll ();

    /**
     * 根据参数查询
     * @param agencyRecord
     * @return
     */
    List<AgencyRecord> findByAgencyRecord (AgencyRecord agencyRecord);

    /**
     * 根据关联id和类型查询对象
     * @param agencyRecord
     * @return
     */
    AgencyRecord findByRelation (AgencyRecord agencyRecord);

    /**
     * 根据参数统计数据
     * @param agencyRecord
     * @return
     */
    int countByAgencyRecord (AgencyRecord agencyRecord);

    /**
     * 根据用户分页查询代办信息
     * @param param
     * @return
     */
    List<AgencyVo> findByUserNamePage (AgencyParam param);
}
